type CustomArray = (number | string)[]

let arr1: CustomArray = [1, 2, 3, '4']
let arr2: CustomArray = [1, 'x', 2, 'y', 3, 'z']

console.log(arr1, arr2)